char *snlen = NULL;
char *snwhiteopt = NULL;
char *mpsverout = NULL;
-char *mpsmergeout = NULL;
+char *mpsmergeouts = NULL;
+int mpsmergeout;
char *mpsusedepth = NULL;
char *mpsuseprox = NULL;
{"mpsverout", &mpsverout,
"Version of mapsource file to generate (3,4,5)", NULL,
ARGTYPE_INT },
- {"mpsmergeout", &mpsmergeout, "Merge output with existing file",
+ {"mpsmergeout", &mpsmergeouts, "Merge output with existing file",
NULL, ARGTYPE_BOOL },
{"mpsusedepth", &mpsusedepth,
"Use depth values on output (default is ignore)", NULL,
static void
mps_wr_init(const char *fname)
{
+ if (mpsmergeouts) {
+ mpsmergeout = atoi(mpsmergeouts);
+ }
+
if (mpsmergeout) {
mps_file_out = xfopen(fname, "rb", MYNAME);
if (mps_file_out == NULL) {
- mpsmergeout = NULL;
+ mpsmergeout = 0;
}
else {
fclose(mps_file_out);